Skip to content

Fix remote worktree remove for reused handles#658

Merged
chubes4 merged 1 commit into
mainfrom
fix/issue-658-worktree-remove-current-branch
Jun 12, 2026
Merged

Fix remote worktree remove for reused handles#658
chubes4 merged 1 commit into
mainfrom
fix/issue-658-worktree-remove-current-branch

Conversation

@chubes4

@chubes4 chubes4 commented Jun 12, 2026

Copy link
Copy Markdown
Member

Summary

  • Allow remote workspace worktree remove <repo> <branch> to remove a stored worktree row when the handle slug no longer matches the current branch.
  • Preserve the existing canonical handle lookup first, then fall back to matching registered remote worktrees by repo_name and branch.
  • Add smoke coverage for a reused/stale handle row removed by its current branch.

Verification

  • php -l inc/Workspace/RemoteWorkspaceBackend.php
  • php -l tests/smoke-remote-workspace-backend.php
  • php tests/smoke-remote-workspace-backend.php
  • git diff --check

AI assistance

  • AI assistance: Yes
  • Tool(s): OpenCode (openai/gpt-5.5)
  • Used for: Implementing the remote worktree removal fallback, adding focused smoke coverage, and running targeted verification. Chris remains responsible for review and merge.

@chubes4 chubes4 merged commit 30febf7 into main Jun 12, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant